import React from "react";
import { View } from "@tarojs/components";

type TRiskQueryItemProps = {
  item: {
    id: string;
    title: string;
    company: string;
    measure: string;
    content: string;
  };
  index: string;
};
const RiskQueryDetaiil: React.FC<TRiskQueryItemProps> = ({item,index}) => {
  return (
    <>
      <View className="w-full pb-3">
        <View className="w-full pb-3 text-blue-500">
          {index+1}、{item.title}
        </View>
        <View className="w-full p-3 bg-white rounded-lg shadow-sm">
          <View className="flex justify-between">
            <View className="flex text-xs text-slate-400">
              参考整改措施：
            </View>
            <View className="flex text-xs text-slate-400">
              由{item.company}提供
            </View>
          </View>
          <View className="w-full py-3">
          {item.measure}
          </View>
          <View className="w-full p-3 bg-blue-50 rounded-lg ">
            <View className="text-xs text-slate-400">
            关联的检查内容：
            </View>
            <View className="w-full pt-3">
            {item.content}
            </View>
          </View>
        </View>      
      </View>
    </>
  );
};

export default RiskQueryDetaiil;
